import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { HomeComponent } from 'src/app/view/home/home.component';

const homeRoutes: Routes = [
  {
    path: 'home', component: HomeComponent
    , children: [
      {path: '',redirectTo:'input',pathMatch:'full'},
      {
        path: 'input', loadChildren: '../view-input/view-input.module#ViewInputModule'
      },
      {
        path: 'button', loadChildren: '../view-button/view-button.module#ViewButtonModule'
      },
      {
        path: 'select', loadChildren: '../view-select/view-select.module#ViewSelectModule'
      },
      {
        path: 'radio', loadChildren: '../view-radio/view-radio.module#ViewRadioModule'
      },
      {
        path: 'date-picker', loadChildren: '../view-date-picker/view-date-picker.module#ViewDatePickerModule'
      },
      {
        path: 'modal', loadChildren: '../view-modal/view-modal.module#ViewModalModule'
      },
      {
        path: 'table', loadChildren: '../view-table/view-table.module#ViewTableModule'
      }
    ]
  }
];

@NgModule({
  imports: [RouterModule.forChild(homeRoutes)],
  exports: [RouterModule]
})
export class HomeRoutingModule { }
